home *** CD-ROM | disk | FTP | other *** search
-
-
- (*******************************************************************)
- (* *)
- (* Include File *)
- (* SysFile.inc, v. 0800am, sun, 28.Mar.87, Glen Ellis *)
- (* *)
- (*******************************************************************)
-
-
- (* *)
- (* function:
- (* fetches parameters from text file named SYSFILE.DAT
- (*
- (* file format:
- (* for INDENT.PAS and FIND.PAS applications
- (* the format is list of FILE.TYP
- (* normal ASCII data
- (* terminal delimiter is <0D><0A)
- (* standard CP/M MSDOS text file format
- (* *)
-
-
- (*-------------------------------*)
-
- BEGIN (* INCLUDE *)
-
- (* sent by calling main module *)
- (* SysInFilename := SysPgmName; *)
-
- (*$I-*);
- ASSIGN( SysInFile, SysInFilename );
- RESET( SysInFile );
-
- Writeln(Chr(7));
- Writeln('---------------------------------');
- Writeln(' Checking for ' + SysInFileName);
- Writeln('---------------------------------');
- writeln;
-
- (* work *)
- (* modify user display, based on SysInFileName = SysPgmName *)
- pIOcheck( SysIOcheck );
-
- (*$I+*);
-
- (* local I/O check to capture the IO flag from pIOcheck *)
-
- (*-------------------------------*)
- (* NO I/O Err, so do the routine *)
-
- If not IOerr then
- (* pgm has found the text file OK *)
- begin
-
- (* tracer for user *)
- IF SysUserTrace then
- writeln('-------> SysFile.Inc Reading ',SysInFileName);
-
- IF SysPgmTrace
- then pDelay1;
-
- SysCmdUser := true ; (* enable User Entry Module *)
- SysCmdUserFile := false; (* have the list already *)
- SysCmdUserParm := true ; (* enable User Entry of Parms *)
-
- SysInFileName := ' '; (* empty name *)
- SysInSourceMax := 0; (* initz for reading into array *)
-
- WHILE not eof(SysInFile) do
- begin
-
- (* inc tail-end counter *)
- SysInSourceMax := SysInSourceMax + 1;
-
- (* fetch line *)
- readln(SysInFile,SysInSource[SysInSourceMax]);
-
- end; (* while *)
-
- writeln;
-
- CLOSE( SysInFile );
- pIOcheck( SysIOcheck );
-
- end; (* not IOerror *)
-
-
- (* error recovery *)
- IF IOerr then
- (* procedure IOCHECK has already displayed small message *)
- begin
-
- (* lock the CORE *)
- (* redundancy OK . Clear the Process ! *)
- SysCmdLine := false;
- SysCmdFile := false;
- (**) SysCmdUser := true ;
- SysCmdUserFile := true;
- SysCmdUserParm := true;
-
-
- SysInSourceMax := 0; (* no entries in array *)
-
- SysInFileName := '?'; (* enable Documents module *)
-
- IF SysUserTrace
- then
- begin
- writeln;
- writeln('----------------------------------------------');
- writeln;
- writeln(' ', SysPgmName,' with filename list not found');
- writeln;
- writeln(' User Entry / Documentation coming next.');
- writeln;
- writeln(' wait . . . .');
- pDelay4;
- end;
-
- CLOSE( SysInFile );
- pIOcheck( SysIOcheck );
-
- end;
-
- (**)
- (*
- (* Developer's note to himself :
- (*
- (* Default settings will be manually inserted.
- (* Required originally for INDENT.PRO called by KEYWORD.PRO.
- (* Indent.pro was written into STRING.INC for consistency.
- (* Default output is for a 'running' dBASE/Pascal source file
- (* with indents and comments, but no line numbering.
- (*
- (* These defaults are to be modified for each application
- (* which incorporates the System.Pas CORE module series.
- (*
- (* install defaults above, or here ... but somewhere !
- (*
- (**)
-
- (* Array Has Been Loaded, clean the vars *)
- (*SysInFilename installed above *)
- SysOutFilename := ' ';
- SysInSourceCnt := 0 ;
- (* InSourceMax installed above *)
-
- (* from sysFILE method : Default Operation Modes *)
- SysIndent := true; (* enable indent procedure *)
- SysComment := true; (* enable comment line write *)
- SysLineCnt := false; (* disable line number write *)
- SysVertiate := false; (* disable vertical markers *)
-
- (* Default Operating Parameters *)
- SysIndentNum := 3; (* standard, useful figure *)
- SysIndentPos := 0; (* always *)
- SysLenMax := 79; (* print page *)
-
-
- END; (* INCLUDE *)
-
-
- (*******************************************************************)
- (*<<<>>>*)